<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
    <style>
      * {
        margin: 0;
        padding: 0;
      }
      .box {
        position: relative;
        width: 100%;
        height: 100vh;
        background: skyblue;
        .shopCart {
          position: absolute;
          bottom: 0;
          left: 0;
        }
        .btn {
          position: absolute;
          top: 50px;
          right: 50px;
          background: #49ef49;
          padding: 2px 4px;
          border-radius: 6px;
          cursor: pointer;
        }
        .plus {
          position: absolute;
          width: 28px;
          height: 28px;
          /* border: 2px solid red; */
          border-radius: 50%;
          /* right: 80px;
          top: 80px; */
          .icon {
            width: 28px;
            height: 28px;
            display: flex;
            align-items: center;
            justify-content: center;
          }
        }
      }
      .plus {
        /* cubic-bezier贝塞尔曲线 参数x1 y1 x2 y2 用来代替动画效果 linear 等等 */
        animation: moveY 0.8s cubic-bezier(0.5, -0.5, 1, 1);
      }
      .icon {
        animation: moveX 0.8s linear;
      }
      @keyframes moveY {
        to {
          transform: translateY(var(--y));
        }
      }
      @keyframes moveX {
        to {
          transform: translateX(var(--x));
        }
      }
    </style>
  </head>
  <body>
    <div class="box">
      <div class="shopCart">
        <?xml version="1.0" encoding="UTF-8"?><svg
          width="24"
          height="24"
          viewBox="0 0 48 48"
          fill="none"
          xmlns="http://www.w3.org/2000/svg"
        >
          <path d="M39 32H13L8 12H44L39 32Z" fill="none" />
          <path
            d="M3 6H6.5L8 12M8 12L13 32H39L44 12H8Z"
            stroke="#333"
            stroke-width="4"
            stroke-linecap="round"
            stroke-linejoin="round"
          />
          <circle
            cx="13"
            cy="39"
            r="3"
            stroke="#333"
            stroke-width="4"
            stroke-linecap="round"
            stroke-linejoin="round"
          />
          <circle
            cx="39"
            cy="39"
            r="3"
            stroke="#333"
            stroke-width="4"
            stroke-linecap="round"
            stroke-linejoin="round"
          />
        </svg>
      </div>
      <div class="btn">Click</div>
      <!-- <div class="plus" style="--y: 392px;--x: -392px">
        <div class="icon">
          <?xml version="1.0" encoding="UTF-8"?><svg
            width="24"
            height="24"
            viewBox="0 0 48 48"
            fill="none"
            xmlns="http://www.w3.org/2000/svg"
          >
            <path
              d="M24 44C35.0457 44 44 35.0457 44 24C44 12.9543 35.0457 4 24 4C12.9543 4 4 12.9543 4 24C4 35.0457 12.9543 44 24 44Z"
              fill="none"
              stroke="#333"
              stroke-width="4"
              stroke-linejoin="round"
            />
            <path
              d="M24 16V32"
              stroke="#333"
              stroke-width="4"
              stroke-linecap="round"
              stroke-linejoin="round"
            />
            <path
              d="M16 24L32 24"
              stroke="#333"
              stroke-width="4"
              stroke-linecap="round"
              stroke-linejoin="round"
            />
          </svg>
        </div>
      </div> -->
    </div>
    <script src="./index.js"></script>
  </body>
</html>
